<!DOCTYPE html>
<html>
    <head>
        <meta charset="utf-8" />
        
        <script type="text/javascript">
           /* 
           定义变量表示月份，根据月份输出改月份的季节和应季活动
           */
            var month = 22;
            if(month == 12 || month == 1 || month == 2){
                alert("冬天到了")
            } else if(month >=3 && month <= 5){
                alert("春天到了")
            } else if(month >=6 && month <=8){
                alert("夏天到了")
            } else if(month >= 9 && month <=11){
                alert("秋天到了，")
            } else{
                alert("月份有误")
            }

            switch(month){
                case 3:
                case 4:
                case 5:
                    alert("春天到了2")
                    break;
                case 6:
                case 7:
                case 8:
                    alert("夏天到了2")
                    break;
                case 9:
                case 10:
                case 11:
                    alert("秋天到了，2")
                    break;
                case 12:
                case 1:
                case 2:
                    alert("冬天到了2")
                    break;
                default:
                    alert("月份有误")
                    break;
            }

        </script>
    </head>
    <body>

    </body>
</html>